home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 972 < prev    next >
Encoding:
Internet Message Format  |  1996-08-06  |  2.7 KB

  1. Path: redstone.interpath.net!usenet
  2. From: fortunat@interpath.com (Jumpstile Turner)
  3. Newsgroups: comp.graphics.algorithms,comp.lang.c++,comp.os.ms-windows.programmer.graphics,comp.os.ms-windows.programmer.multimedia,comp.os.ms-windows.programmer.win32
  4. Subject: Re: IJG JPEG Engine and Win32
  5. Date: 8 Jan 1996 18:29:09 GMT
  6. Organization: Completely unorganized
  7. Message-ID: <4crnpl$k49@redstone.interpath.net>
  8. References: <4cemir$6vb@redstone.interpath.net> <TGL.96Jan3202549@netcom21.netcom.com> <TGL.96Jan8083559@netcom23.netcom.com>
  9. NNTP-Posting-Host: fortunat.pdial.interpath.net
  10. X-Newsreader: WinVN 0.99.7
  11.  
  12. In article <TGL.96Jan8083559@netcom23.netcom.com>, tgl@netcom.com said:
  13. >
  14. >fortunat@interpath.com (Jumpstile Turner) writes:
  15. >> Checking the cinfo structure after it comes 
  16. >> back from jpeg_read_header shows that cinfo.image_width and 
  17. >> cinfo.image_height are correct, however almost every field with  
  18. >> "output_xxxx" is way off, either 1, 0, or some rediculous number 
  19. >> like 7988774.
  20. >
  21. >Then you've still got a problem with sizeof(boolean), I'd bet,
  22. >or else a structure packing rule (#pragma pack).  Are you sure
  23. >you recompiled everything affected by the header files you changed?
  24. >
  25. >It might help to #include jpeglib.h *before* including any Windows-
  26. >specific headers... if one of their headers is leaving #pragma pack
  27. >in a nondefault state, that could cause this problem.
  28. >
  29. >                        regards, tom lane
  30. >                        organizer, Independent JPEG Group
  31.  
  32.  
  33.    Well, I've got it working flawlessly now. :) In fact the problem was 
  34. entirely related to one specific Borland compiler setting.  Allocate 
  35. enums as int.  This was causing all sorts of problems.  I had to have 
  36. this set or borland packs enums.  I was looking for the word 
  37. "structure"and I didn't pay much attention to this setting.  Like I 
  38. figured, it was something stupid on my end.
  39.    Incidently, I changed (and have been changing) a lot of stuff over 
  40. to Win32 API calls, memory and file handling.  It sure seems a lot 
  41. faster now as opposed to using the standard C stuff, but this might be 
  42. my imagination.  Maybe I'll add multi-threading now that I have a 
  43. handle on this thing. :)
  44.  
  45.  
  46.    Thanks for all the help.  You really cleared up a lot of things for 
  47. me and I learned a LOT (About the JPEG code too. :) )
  48.  
  49.              -Scott  
  50.  
  51.  
  52. P.S.   If anyone reading this thread is interested in my hacked up 
  53. version of the .LIB let me know.  I've been using it on hundreds of 
  54. images now to make sure there are no strange memory leaks and it hasn't 
  55. burped even once.
  56.  
  57.  
  58.  
  59. ------------------------------------------------
  60. Jumpstile Turner
  61. fortunat@interpath.com
  62. "Sing the Hare Hare, Dance the Hoochie Koo..."
  63. ------------------------------------------------
  64.  
  65.